package controllers

import (
	"net/http"

	"github.com/gin-gonic/gin"

	"library/models"
)

// 查看操作日志列表
func GetLogs(c *gin.Context) {
	var logs []models.Log
	DB.Order("timestamp desc").Find(&logs)
	c.HTML(http.StatusOK, "log_list.html", gin.H{"Logs": logs})
}
